package org.dromara.agriculture.domain.bo;

import org.dromara.agriculture.domain.AgricultureCostMaterial;
import org.dromara.common.mybatis.core.domain.BaseEntity;
import org.dromara.common.core.validate.AddGroup;
import org.dromara.common.core.validate.EditGroup;
import io.github.linpeilie.annotations.AutoMapper;
import lombok.Data;
import lombok.EqualsAndHashCode;
import jakarta.validation.constraints.*;

/**
 * 农资用量业务对象 agriculture_cost_material
 *
 * @author Robin
 * @date 2024-12-05
 */
@Data
@EqualsAndHashCode(callSuper = true)
@AutoMapper(target = AgricultureCostMaterial.class, reverseConvertGenerate = false)
public class AgricultureCostMaterialBo extends BaseEntity {

    /**
     * ID
     */
    @NotNull(message = "ID不能为空", groups = { EditGroup.class })
    private Long costId;

    /**
     * 任务ID
     */
    @NotNull(message = "任务ID不能为空", groups = { AddGroup.class, EditGroup.class })
    private Long taskId;

    /**
     * 农资ID
     */
    @NotNull(message = "农资ID不能为空", groups = { AddGroup.class, EditGroup.class })
    private Long materialId;

    /**
     * 使用数量
     */
    @NotNull(message = "使用数量不能为空", groups = { AddGroup.class, EditGroup.class })
    private Long materialCount;

    /**
     * 计量单位
     */
    @NotBlank(message = "计量单位不能为空", groups = { AddGroup.class, EditGroup.class })
    private String measureUnit;

    /**
     * 开始日期
     */
    @NotBlank(message = "开始日期不能为空", groups = { AddGroup.class, EditGroup.class })
    private String workingStart;

    /**
     * 结束日期
     */
    @NotBlank(message = "结束日期不能为空", groups = { AddGroup.class, EditGroup.class })
    private String workingFinish;

    /**
     * 备注
     */
    @NotBlank(message = "备注不能为空", groups = { AddGroup.class, EditGroup.class })
    private String remark;

    /**
     * 状态
     */
    @NotBlank(message = "状态不能为空", groups = { AddGroup.class, EditGroup.class })
    private String status;

    /**
     * 排序
     */
    @NotNull(message = "排序不能为空", groups = { AddGroup.class, EditGroup.class })
    private Long orderNum;


}
